package com.hang.ixin.Enums;

import lombok.Getter;

@Getter
public enum OptStatusEnum {
    IGNORE(0,"忽略"),
    PASS(1,"同意")
    ;
    private Integer status;
    private String msg;

    OptStatusEnum(Integer status, String msg) {
        this.status = status;
        this.msg = msg;
    }

    public static String getMsgByStatus(Integer status){
        for (OptStatusEnum instance : OptStatusEnum.values()){
            if(instance.getStatus() == status){
                return instance.getMsg();
            }
        }
        return null;
    }
}
